package org.example.curriculum_design_6_16.service;

import io.swagger.models.auth.In;
import org.example.curriculum_design_6_16.entity.pojo.Grade;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;
/**
* @author 郑凯
* @description 针对表【grade】的数据库操作Service
* @createDate 2025-06-16 09:25:48
*/
public interface GradeService extends IService<Grade> {
    boolean addGrade(Grade grade);

    boolean deleteGradeById(Integer id);

    boolean updateGrade(Grade grade);

    public Grade getGradeById(String studentId, String courseId);

    List<Grade> getAllGrades();

    List<Grade> getGradesByStudentId(String studentId);

    List<Grade> getGradesByCourseId(String courseId);

    boolean deleteGradesByStudentId(String studentId);

    Double getAverageGradeByCourse(String courseId);

    boolean existsGradeForStudentAndCourse(String studentId, String courseId);

    boolean updateGradeRemark(Integer gradeId, String remark);

    public List<Grade> getGradesByStudentIdEFF(String studentId);
}
